import numpy as np 
import pymysql
import json
db = pymysql.connect("localhost","root","root","ibeacon_kc",use_unicode=True, charset="utf8")
cursor = db.cursor()
sql = "SELECT * FROM tf_blts_camera"

cursor.execute(sql)
# 获取所有记录列表
names = locals()
results = cursor.fetchall()
db.close()

arr = [range(0,len(results))] 
for key in range(0,len(results)):
	row = results[key]
	arr[key] = row
	#print(np.float32(json.loads(row[5])))

print(arr)